#!/bin/bash
declare -a RA=(690867 078938 046789 039363 098765 090200 050123 046127 690367 028888 690067 690667 690767 690167 045638 045633 690267 048221 029999 134758 692067 056479 691067 035177 690967 039765 041220 041222 044044 044045 690467 080115 020991 044029 037392 098373 090100 690567 031015 031016 074029);

for ra in "${RA[@]}"
do
    output=$(curl -s "http://www.students.ic.unicamp.br/~ra104864/mc857/servidorDac/rest/obter_dados.php?ra=$ra")
    if  [[ $output == bad* ]] ;
    then
        echo $ra
    fi
done